package ooday04;

public class StaffTest {
    public static void main(String[] args) {
        Director zs = new Director("张三",35,100000);
        zs.goToWork();
        zs.afterWork();
        zs.finishWork();
        zs.solve();
        zs.train();
        zs.edit();
        System.out.println();

        Lecturer[] lecturer = new Lecturer[2];
        lecturer[0] = new Lecturer("李四",30,50000);
        lecturer[1] = new Lecturer("王五",30,50000);
        for (int i = 0; i <lecturer.length ; i++) {
            lecturer[i].goToWork();
            lecturer[i].afterWork();
            lecturer[i].finishWork();
            lecturer[i].solve();
            lecturer[i].train();
            lecturer[i].edit();
            System.out.println();
        }

        Manger[] manger = new Manger[3];
        manger[2] = new Manger("赵六",28,30000);
        System.out.println(manger[2].name);
        System.out.println(manger[2].name+"的工资为"+manger[2].salary);
        System.out.println();

        Teacher[] teacher = new Teacher[5];
        teacher[0] = new Teacher("老师一",21,21000);
        teacher[1] = new Teacher("老师二",22,22000);
        teacher[2] = new Teacher("老师三",23,23000);
        teacher[3] = new Teacher("老师四",24,24000);
        teacher[4] = new Teacher("老师五",25,25000);
        for (int i = 0; i <teacher.length ; i++) {
            teacher[i].goToWork();
            teacher[i].afterWork();
            teacher[i].finishWork();
            System.out.println("我的名字是"+teacher[i].name+"，今年"+teacher[i].age+"岁，我的工资为"+teacher[i].salary);
            System.out.println();
        }
    }
}
